<!DOCTYPE html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=2">
<meta name="theme-color" content="#222">
<meta name="generator" content="Hexo 5.4.2">
  <link rel="apple-touch-icon" sizes="180x180" href="/images/apple-touch-icon-next.png">
  <link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32-next.png">
  <link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16-next.png">
  <link rel="mask-icon" href="/images/logo.svg" color="#222">

<link rel="stylesheet" href="/css/main.css">


<link rel="stylesheet" href="/lib/font-awesome/css/all.min.css">

<script id="hexo-configurations">
    var NexT = window.NexT || {};
    var CONFIG = {"hostname":"wrr123.github.io","root":"/","scheme":"Muse","version":"7.8.0","exturl":false,"sidebar":{"position":"left","display":"post","padding":18,"offset":12,"onmobile":false},"copycode":{"enable":false,"show_result":false,"style":null},"back2top":{"enable":true,"sidebar":false,"scrollpercent":false},"bookmark":{"enable":false,"color":"#222","save":"auto"},"fancybox":false,"mediumzoom":false,"lazyload":false,"pangu":false,"comments":{"style":"tabs","active":null,"storage":true,"lazyload":false,"nav":null},"algolia":{"hits":{"per_page":10},"labels":{"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}},"localsearch":{"enable":true,"trigger":"auto","top_n_per_article":1,"unescape":false,"preload":false},"motion":{"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}},"path":"search.json"};
  </script>

  <meta name="description" content="Thu Dec 12 12:58:02 CST 2019git和svn相结合？(Version Control System) 更新(git svn rebase) 提交(git svn dcommit)  Wed Dec 18 08:47:29 CST 2019git pull出现冲突时的几种解决方法？ cnblogs  Thu Dec 19 09:39:51 CST 2019 Sat Dec">
<meta property="og:type" content="article">
<meta property="og:title" content="notebook-git">
<meta property="og:url" content="https://wrr123.github.io/2020/08/16/notebook-git/index.html">
<meta property="og:site_name" content="一缕烟气">
<meta property="og:description" content="Thu Dec 12 12:58:02 CST 2019git和svn相结合？(Version Control System) 更新(git svn rebase) 提交(git svn dcommit)  Wed Dec 18 08:47:29 CST 2019git pull出现冲突时的几种解决方法？ cnblogs  Thu Dec 19 09:39:51 CST 2019 Sat Dec">
<meta property="og:locale" content="zh_CN">
<meta property="article:published_time" content="2020-08-15T16:42:17.000Z">
<meta property="article:modified_time" content="2022-02-18T02:52:04.494Z">
<meta property="article:author" content="田园隐士">
<meta property="article:tag" content="notebook">
<meta name="twitter:card" content="summary">

<link rel="canonical" href="https://wrr123.github.io/2020/08/16/notebook-git/">


<script id="page-configurations">
  // https://hexo.io/docs/variables.html
  CONFIG.page = {
    sidebar: "",
    isHome : false,
    isPost : true,
    lang   : 'zh-CN'
  };
</script>

  <title>notebook-git | 一缕烟气</title>
  






  <noscript>
  <style>
  .use-motion .brand,
  .use-motion .menu-item,
  .sidebar-inner,
  .use-motion .post-block,
  .use-motion .pagination,
  .use-motion .comments,
  .use-motion .post-header,
  .use-motion .post-body,
  .use-motion .collection-header { opacity: initial; }

  .use-motion .site-title,
  .use-motion .site-subtitle {
    opacity: initial;
    top: initial;
  }

  .use-motion .logo-line-before i { left: initial; }
  .use-motion .logo-line-after i { right: initial; }
  </style>
</noscript>

<link rel="alternate" href="/atom.xml" title="一缕烟气" type="application/atom+xml">
</head>

<body itemscope itemtype="http://schema.org/WebPage">
  <div class="container use-motion">
    <div class="headband"></div>

    <header class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-container">
  <div class="site-nav-toggle">
    <div class="toggle" aria-label="切换导航栏">
      <span class="toggle-line toggle-line-first"></span>
      <span class="toggle-line toggle-line-middle"></span>
      <span class="toggle-line toggle-line-last"></span>
    </div>
  </div>

  <div class="site-meta">

    <a href="/" class="brand" rel="start">
      <span class="logo-line-before"><i></i></span>
      <h1 class="site-title">一缕烟气</h1>
      <span class="logo-line-after"><i></i></span>
    </a>
      <p class="site-subtitle" itemprop="description">沧海月明珠有泪，蓝田日暖玉生烟</p>
  </div>

  <div class="site-nav-right">
    <div class="toggle popup-trigger">
        <i class="fa fa-search fa-fw fa-lg"></i>
    </div>
  </div>
</div>




<nav class="site-nav">
  <ul id="menu" class="main-menu menu">
        <li class="menu-item menu-item-home">

    <a href="/" rel="section"><i class="fa fa-home fa-fw"></i>首页</a>

  </li>
        <li class="menu-item menu-item-archives">

    <a href="/archives/" rel="section"><i class="fa fa-archive fa-fw"></i>归档</a>

  </li>
      <li class="menu-item menu-item-search">
        <a role="button" class="popup-trigger"><i class="fa fa-search fa-fw"></i>搜索
        </a>
      </li>
  </ul>
</nav>



  <div class="search-pop-overlay">
    <div class="popup search-popup">
        <div class="search-header">
  <span class="search-icon">
    <i class="fa fa-search"></i>
  </span>
  <div class="search-input-container">
    <input autocomplete="off" autocapitalize="off"
           placeholder="搜索..." spellcheck="false"
           type="search" class="search-input">
  </div>
  <span class="popup-btn-close">
    <i class="fa fa-times-circle"></i>
  </span>
</div>
<div id="search-result">
  <div id="no-result">
    <i class="fa fa-spinner fa-pulse fa-5x fa-fw"></i>
  </div>
</div>

    </div>
  </div>

</div>
    </header>

    
  <div class="back-to-top">
    <i class="fa fa-arrow-up"></i>
    <span>0%</span>
  </div>


    <main class="main">
      <div class="main-inner">
        <div class="content-wrap">
          

          <div class="content post posts-expand">
            

    
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="zh-CN">
    <link itemprop="mainEntityOfPage" href="https://wrr123.github.io/2020/08/16/notebook-git/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/images/avatar.gif">
      <meta itemprop="name" content="田园隐士">
      <meta itemprop="description" content="talk is cheap, show me the code">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="一缕烟气">
    </span>
      <header class="post-header">
        <h1 class="post-title" itemprop="name headline">
          notebook-git
        </h1>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>

              <time title="创建时间：2020-08-16 00:42:17" itemprop="dateCreated datePublished" datetime="2020-08-16T00:42:17+08:00">2020-08-16</time>
            </span>
              <span class="post-meta-item">
                <span class="post-meta-item-icon">
                  <i class="far fa-calendar-check"></i>
                </span>
                <span class="post-meta-item-text">更新于</span>
                <time title="修改时间：2022-02-18 10:52:04" itemprop="dateModified" datetime="2022-02-18T10:52:04+08:00">2022-02-18</time>
              </span>

          
            <span class="post-meta-item" title="阅读次数" id="busuanzi_container_page_pv" style="display: none;">
              <span class="post-meta-item-icon">
                <i class="fa fa-eye"></i>
              </span>
              <span class="post-meta-item-text">阅读次数：</span>
              <span id="busuanzi_value_page_pv"></span>
            </span><br>
            <span class="post-meta-item" title="本文字数">
              <span class="post-meta-item-icon">
                <i class="far fa-file-word"></i>
              </span>
                <span class="post-meta-item-text">本文字数：</span>
              <span>1.3k</span>
            </span>
            <span class="post-meta-item" title="阅读时长">
              <span class="post-meta-item-icon">
                <i class="far fa-clock"></i>
              </span>
                <span class="post-meta-item-text">阅读时长 &asymp;</span>
              <span>1 分钟</span>
            </span>

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
        <h1 id="Thu-Dec-12-12-58-02-CST-2019"><a href="#Thu-Dec-12-12-58-02-CST-2019" class="headerlink" title="Thu Dec 12 12:58:02 CST 2019"></a>Thu Dec 12 12:58:02 CST 2019</h1><h2 id="git和svn相结合？-Version-Control-System"><a href="#git和svn相结合？-Version-Control-System" class="headerlink" title="git和svn相结合？(Version Control System)"></a>git和svn相结合？(Version Control System)</h2><ul>
<li>更新(git svn rebase)</li>
<li>提交(git svn dcommit)</li>
</ul>
<h1 id="Wed-Dec-18-08-47-29-CST-2019"><a href="#Wed-Dec-18-08-47-29-CST-2019" class="headerlink" title="Wed Dec 18 08:47:29 CST 2019"></a>Wed Dec 18 08:47:29 CST 2019</h1><h2 id="git-pull出现冲突时的几种解决方法？"><a href="#git-pull出现冲突时的几种解决方法？" class="headerlink" title="git pull出现冲突时的几种解决方法？"></a>git pull出现冲突时的几种解决方法？</h2><blockquote>
<p><a target="_blank" rel="noopener" href="https://www.cnblogs.com/zjfjava/p/10280247.html">cnblogs</a></p>
</blockquote>
<h1 id="Thu-Dec-19-09-39-51-CST-2019"><a href="#Thu-Dec-19-09-39-51-CST-2019" class="headerlink" title="Thu Dec 19 09:39:51 CST 2019"></a>Thu Dec 19 09:39:51 CST 2019</h1><h2 id><a href="#" class="headerlink" title=" "></a> </h2><h1 id="Sat-Dec-21-16-18-56-CST-2019"><a href="#Sat-Dec-21-16-18-56-CST-2019" class="headerlink" title="Sat Dec 21 16:18:56 CST 2019"></a>Sat Dec 21 16:18:56 CST 2019</h1><h2 id="git-diff"><a href="#git-diff" class="headerlink" title="git diff"></a>git diff</h2><ul>
<li>默认比较工作空间文件和未提交到缓存空间的文件；<h2 id="git-diff-—staged"><a href="#git-diff-—staged" class="headerlink" title="git diff —staged"></a>git diff —staged</h2></li>
<li>比较工作空间文件和缓存空间的文件;<h2 id="git账号设置公匙-SSH-KEY"><a href="#git账号设置公匙-SSH-KEY" class="headerlink" title="git账号设置公匙(SSH-KEY)"></a>git账号设置公匙(SSH-KEY)</h2><figure class="highlight shell"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br></pre></td><td class="code"><pre><span class="line">ssh-keygen -t rsa -C 账号 -f 生成的公匙文件的全路径名</span><br><span class="line"><span class="meta prompt_"># </span><span class="language-bash">复制公匙文件的代码到github的添加公匙处</span></span><br><span class="line"><span class="meta prompt_"># </span><span class="language-bash">测试是否添加成功</span></span><br><span class="line">ssh -T git@github.com</span><br><span class="line"><span class="meta prompt_"># </span><span class="language-bash">提示如下表示成功</span></span><br><span class="line"><span class="meta prompt_"># </span><span class="language-bash">Hi wrr123! You<span class="string">&#x27;ve successfully authenticated, but GitHub does not provide shell access.</span></span></span><br></pre></td></tr></table></figure>
</li>
</ul>
<h1 id="Sun-Dec-22-11-22-50-CST-2019"><a href="#Sun-Dec-22-11-22-50-CST-2019" class="headerlink" title="Sun Dec 22 11:22:50 CST 2019"></a>Sun Dec 22 11:22:50 CST 2019</h1><h2 id="git打包"><a href="#git打包" class="headerlink" title="git打包"></a>git打包</h2><ul>
<li>git archive<ol>
<li>打包最后一个版本修改的文件<br><code>git archive --format=zip -o update.zip HEAD $(git diff --name-only HEAD^)</code></li>
</ol>
</li>
<li>git bundle<h2 id="git-rebase"><a href="#git-rebase" class="headerlink" title="git rebase"></a>git rebase</h2></li>
<li>合并分支</li>
<li>合并提交的记录</li>
</ul>
<h1 id="Wed-Dec-25-21-56-53-CST-2019"><a href="#Wed-Dec-25-21-56-53-CST-2019" class="headerlink" title="Wed Dec 25 21:56:53 CST 2019"></a>Wed Dec 25 21:56:53 CST 2019</h1><h2 id="submodule"><a href="#submodule" class="headerlink" title="submodule"></a>submodule</h2><ul>
<li>更新子模块中还存在子模块的项目<br><code>git submodule foreach git submodule update</code></li>
</ul>
<h1 id="Thu-Dec-26-10-19-19-CST-2019"><a href="#Thu-Dec-26-10-19-19-CST-2019" class="headerlink" title="Thu Dec 26 10:19:19 CST 2019"></a>Thu Dec 26 10:19:19 CST 2019</h1><h2 id="Git-遇到了-early-EOF-index-pack-failed-问题"><a href="#Git-遇到了-early-EOF-index-pack-failed-问题" class="headerlink" title="Git 遇到了 early EOF index-pack failed 问题?"></a>Git 遇到了 early EOF index-pack failed 问题?</h2><figure class="highlight plaintext"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line"># 为 git 添加配置项，通过下面的命令可以简单完成</span><br><span class="line"># 在这之前可以执行 git config -l 命令看看已有配置项有哪些</span><br><span class="line">git config --add core.compression -1</span><br></pre></td></tr></table></figure>
<h2 id="将工作空间中的文件-已经提交过git仓库的-设置成状态为忽略的-即不需要提交到git仓库-？"><a href="#将工作空间中的文件-已经提交过git仓库的-设置成状态为忽略的-即不需要提交到git仓库-？" class="headerlink" title="将工作空间中的文件(已经提交过git仓库的)设置成状态为忽略的(即不需要提交到git仓库)？"></a>将工作空间中的文件(已经提交过git仓库的)设置成状态为忽略的(即不需要提交到git仓库)？</h2><figure class="highlight shell"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">git st --short|awk &#x27;&#123;print $2&#125;&#x27;|xargs git update-index --assume-unchanged</span><br></pre></td></tr></table></figure>
<h2 id="查看使用git-update-index-assume-unchanged忽略的文件-并将其状态设为正常"><a href="#查看使用git-update-index-assume-unchanged忽略的文件-并将其状态设为正常" class="headerlink" title="查看使用git update-index --assume-unchanged忽略的文件,并将其状态设为正常?"></a>查看使用<code>git update-index --assume-unchanged</code>忽略的文件,并将其状态设为正常?</h2><figure class="highlight shell"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line">git ls-files -v |grep &#x27;^h&#x27;|awk &#x27;&#123;print $2&#125;&#x27;|xargs git update-index --no-assume-unchanged</span><br></pre></td></tr></table></figure>
<h2 id="问题-使用了git-update-index-assume-unchanged忽略的文件之后，再使用git-stash储藏工作空间变更的文件，然后使用git-stash-pop释放储藏的文件时，会将之前忽略的文件修改的内容全部还原-为啥？"><a href="#问题-使用了git-update-index-assume-unchanged忽略的文件之后，再使用git-stash储藏工作空间变更的文件，然后使用git-stash-pop释放储藏的文件时，会将之前忽略的文件修改的内容全部还原-为啥？" class="headerlink" title="问题: 使用了git update-index --assume-unchanged忽略的文件之后，再使用git stash储藏工作空间变更的文件，然后使用git stash pop释放储藏的文件时，会将之前忽略的文件修改的内容全部还原,为啥？"></a>问题: 使用了<code>git update-index --assume-unchanged</code>忽略的文件之后，再使用<code>git stash</code>储藏工作空间变更的文件，然后使用<code>git stash pop</code>释放储藏的文件时，会将之前忽略的文件修改的内容全部还原,为啥？</h2><h1 id="2020年-1月-2日-星期四-10时36分40秒-CST"><a href="#2020年-1月-2日-星期四-10时36分40秒-CST" class="headerlink" title="2020年 1月 2日 星期四 10时36分40秒 CST"></a>2020年 1月 2日 星期四 10时36分40秒 CST</h1><h2 id="NUL-termination的含义"><a href="#NUL-termination的含义" class="headerlink" title="NUL termination的含义"></a><code>NUL termination</code>的含义</h2><p>空字符串(null charactor),亦称结束符。</p>

    </div>

    
    
    
        

  <div class="followme">
    <p>欢迎关注我的其它发布渠道</p>

    <div class="social-list">

        <div class="social-item">
          <a target="_blank" class="social-link" href="/atom.xml">
            <span class="icon">
              <i class="fa fa-rss"></i>
            </span>

            <span class="label">RSS</span>
          </a>
        </div>
    </div>
  </div>


      <footer class="post-footer">
          <div class="post-tags">
              <a href="/tags/notebook/" rel="tag"># notebook</a>
          </div>

        


        
    <div class="post-nav">
      <div class="post-nav-item">
    <a href="/2020/08/16/notebook-gradle/" rel="prev" title="notebook-gradle">
      <i class="fa fa-chevron-left"></i> notebook-gradle
    </a></div>
      <div class="post-nav-item">
    <a href="/2020/08/16/notebook-emacs/" rel="next" title="notebook-emacs">
      notebook-emacs <i class="fa fa-chevron-right"></i>
    </a></div>
    </div>
      </footer>
    
  </article>
  
  
  



          </div>
          

<script>
  window.addEventListener('tabs:register', () => {
    let { activeClass } = CONFIG.comments;
    if (CONFIG.comments.storage) {
      activeClass = localStorage.getItem('comments_active') || activeClass;
    }
    if (activeClass) {
      let activeTab = document.querySelector(`a[href="#comment-${activeClass}"]`);
      if (activeTab) {
        activeTab.click();
      }
    }
  });
  if (CONFIG.comments.storage) {
    window.addEventListener('tabs:click', event => {
      if (!event.target.matches('.tabs-comment .tab-content .tab-pane')) return;
      let commentClass = event.target.classList[1];
      localStorage.setItem('comments_active', commentClass);
    });
  }
</script>

        </div>
          
  
  <div class="toggle sidebar-toggle">
    <span class="toggle-line toggle-line-first"></span>
    <span class="toggle-line toggle-line-middle"></span>
    <span class="toggle-line toggle-line-last"></span>
  </div>

  <aside class="sidebar">
    <div class="sidebar-inner">

      <ul class="sidebar-nav motion-element">
        <li class="sidebar-nav-toc">
          文章目录
        </li>
        <li class="sidebar-nav-overview">
          站点概览
        </li>
      </ul>

      <!--noindex-->
      <div class="post-toc-wrap sidebar-panel">
          <div class="post-toc motion-element"><ol class="nav"><li class="nav-item nav-level-1"><a class="nav-link" href="#Thu-Dec-12-12-58-02-CST-2019"><span class="nav-number">1.</span> <span class="nav-text">Thu Dec 12 12:58:02 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#git%E5%92%8Csvn%E7%9B%B8%E7%BB%93%E5%90%88%EF%BC%9F-Version-Control-System"><span class="nav-number">1.1.</span> <span class="nav-text">git和svn相结合？(Version Control System)</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#Wed-Dec-18-08-47-29-CST-2019"><span class="nav-number">2.</span> <span class="nav-text">Wed Dec 18 08:47:29 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#git-pull%E5%87%BA%E7%8E%B0%E5%86%B2%E7%AA%81%E6%97%B6%E7%9A%84%E5%87%A0%E7%A7%8D%E8%A7%A3%E5%86%B3%E6%96%B9%E6%B3%95%EF%BC%9F"><span class="nav-number">2.1.</span> <span class="nav-text">git pull出现冲突时的几种解决方法？</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#Thu-Dec-19-09-39-51-CST-2019"><span class="nav-number">3.</span> <span class="nav-text">Thu Dec 19 09:39:51 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link"><span class="nav-number">3.1.</span> <span class="nav-text"> </span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#Sat-Dec-21-16-18-56-CST-2019"><span class="nav-number">4.</span> <span class="nav-text">Sat Dec 21 16:18:56 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#git-diff"><span class="nav-number">4.1.</span> <span class="nav-text">git diff</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#git-diff-%E2%80%94staged"><span class="nav-number">4.2.</span> <span class="nav-text">git diff —staged</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#git%E8%B4%A6%E5%8F%B7%E8%AE%BE%E7%BD%AE%E5%85%AC%E5%8C%99-SSH-KEY"><span class="nav-number">4.3.</span> <span class="nav-text">git账号设置公匙(SSH-KEY)</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#Sun-Dec-22-11-22-50-CST-2019"><span class="nav-number">5.</span> <span class="nav-text">Sun Dec 22 11:22:50 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#git%E6%89%93%E5%8C%85"><span class="nav-number">5.1.</span> <span class="nav-text">git打包</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#git-rebase"><span class="nav-number">5.2.</span> <span class="nav-text">git rebase</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#Wed-Dec-25-21-56-53-CST-2019"><span class="nav-number">6.</span> <span class="nav-text">Wed Dec 25 21:56:53 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#submodule"><span class="nav-number">6.1.</span> <span class="nav-text">submodule</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#Thu-Dec-26-10-19-19-CST-2019"><span class="nav-number">7.</span> <span class="nav-text">Thu Dec 26 10:19:19 CST 2019</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#Git-%E9%81%87%E5%88%B0%E4%BA%86-early-EOF-index-pack-failed-%E9%97%AE%E9%A2%98"><span class="nav-number">7.1.</span> <span class="nav-text">Git 遇到了 early EOF index-pack failed 问题?</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E5%B0%86%E5%B7%A5%E4%BD%9C%E7%A9%BA%E9%97%B4%E4%B8%AD%E7%9A%84%E6%96%87%E4%BB%B6-%E5%B7%B2%E7%BB%8F%E6%8F%90%E4%BA%A4%E8%BF%87git%E4%BB%93%E5%BA%93%E7%9A%84-%E8%AE%BE%E7%BD%AE%E6%88%90%E7%8A%B6%E6%80%81%E4%B8%BA%E5%BF%BD%E7%95%A5%E7%9A%84-%E5%8D%B3%E4%B8%8D%E9%9C%80%E8%A6%81%E6%8F%90%E4%BA%A4%E5%88%B0git%E4%BB%93%E5%BA%93-%EF%BC%9F"><span class="nav-number">7.2.</span> <span class="nav-text">将工作空间中的文件(已经提交过git仓库的)设置成状态为忽略的(即不需要提交到git仓库)？</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E6%9F%A5%E7%9C%8B%E4%BD%BF%E7%94%A8git-update-index-assume-unchanged%E5%BF%BD%E7%95%A5%E7%9A%84%E6%96%87%E4%BB%B6-%E5%B9%B6%E5%B0%86%E5%85%B6%E7%8A%B6%E6%80%81%E8%AE%BE%E4%B8%BA%E6%AD%A3%E5%B8%B8"><span class="nav-number">7.3.</span> <span class="nav-text">查看使用git update-index --assume-unchanged忽略的文件,并将其状态设为正常?</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E9%97%AE%E9%A2%98-%E4%BD%BF%E7%94%A8%E4%BA%86git-update-index-assume-unchanged%E5%BF%BD%E7%95%A5%E7%9A%84%E6%96%87%E4%BB%B6%E4%B9%8B%E5%90%8E%EF%BC%8C%E5%86%8D%E4%BD%BF%E7%94%A8git-stash%E5%82%A8%E8%97%8F%E5%B7%A5%E4%BD%9C%E7%A9%BA%E9%97%B4%E5%8F%98%E6%9B%B4%E7%9A%84%E6%96%87%E4%BB%B6%EF%BC%8C%E7%84%B6%E5%90%8E%E4%BD%BF%E7%94%A8git-stash-pop%E9%87%8A%E6%94%BE%E5%82%A8%E8%97%8F%E7%9A%84%E6%96%87%E4%BB%B6%E6%97%B6%EF%BC%8C%E4%BC%9A%E5%B0%86%E4%B9%8B%E5%89%8D%E5%BF%BD%E7%95%A5%E7%9A%84%E6%96%87%E4%BB%B6%E4%BF%AE%E6%94%B9%E7%9A%84%E5%86%85%E5%AE%B9%E5%85%A8%E9%83%A8%E8%BF%98%E5%8E%9F-%E4%B8%BA%E5%95%A5%EF%BC%9F"><span class="nav-number">7.4.</span> <span class="nav-text">问题: 使用了git update-index --assume-unchanged忽略的文件之后，再使用git stash储藏工作空间变更的文件，然后使用git stash pop释放储藏的文件时，会将之前忽略的文件修改的内容全部还原,为啥？</span></a></li></ol></li><li class="nav-item nav-level-1"><a class="nav-link" href="#2020%E5%B9%B4-1%E6%9C%88-2%E6%97%A5-%E6%98%9F%E6%9C%9F%E5%9B%9B-10%E6%97%B636%E5%88%8640%E7%A7%92-CST"><span class="nav-number">8.</span> <span class="nav-text">2020年 1月 2日 星期四 10时36分40秒 CST</span></a><ol class="nav-child"><li class="nav-item nav-level-2"><a class="nav-link" href="#NUL-termination%E7%9A%84%E5%90%AB%E4%B9%89"><span class="nav-number">8.1.</span> <span class="nav-text">NUL termination的含义</span></a></li></ol></li></ol></div>
      </div>
      <!--/noindex-->

      <div class="site-overview-wrap sidebar-panel">
        <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
  <p class="site-author-name" itemprop="name">田园隐士</p>
  <div class="site-description" itemprop="description">talk is cheap, show me the code</div>
</div>
<div class="site-state-wrap motion-element">
  <nav class="site-state">
      <div class="site-state-item site-state-posts">
          <a href="/archives/">
        
          <span class="site-state-item-count">347</span>
          <span class="site-state-item-name">日志</span>
        </a>
      </div>
      <div class="site-state-item site-state-categories">
            <a href="/categories/">
        <span class="site-state-item-count">53</span>
        <span class="site-state-item-name">分类</span></a>
      </div>
      <div class="site-state-item site-state-tags">
            <a href="/tags/">
        <span class="site-state-item-count">115</span>
        <span class="site-state-item-name">标签</span></a>
      </div>
  </nav>
</div>



      </div>

    </div>
  </aside>
  <div id="sidebar-dimmer"></div>


      </div>
    </main>

    <footer class="footer">
      <div class="footer-inner">
        

        

<div class="copyright">
  
  &copy; 
  <span itemprop="copyrightYear">2022</span>
  <span class="with-love">
    <i class="fa fa-heart"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">田园隐士</span>
    <span class="post-meta-divider">|</span>
    <span class="post-meta-item-icon">
      <i class="fa fa-chart-area"></i>
    </span>
    <span title="站点总字数">587k</span>
    <span class="post-meta-divider">|</span>
    <span class="post-meta-item-icon">
      <i class="fa fa-coffee"></i>
    </span>
    <span title="站点阅读时长">8:53</span>
</div>
  <div class="powered-by">由 <a href="https://hexo.io/" class="theme-link" rel="noopener" target="_blank">Hexo</a> & <a href="https://muse.theme-next.org/" class="theme-link" rel="noopener" target="_blank">NexT.Muse</a> 强力驱动
  </div>

        
<div class="busuanzi-count">
  <script async src="https://busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script>
    <span class="post-meta-item" id="busuanzi_container_site_uv" style="display: none;">
      <span class="post-meta-item-icon">
        <i class="fa fa-user"></i>
      </span>
      <span class="site-uv" title="总访客量">
        <span id="busuanzi_value_site_uv"></span>
      </span>
    </span>
    <span class="post-meta-divider">|</span>
    <span class="post-meta-item" id="busuanzi_container_site_pv" style="display: none;">
      <span class="post-meta-item-icon">
        <i class="fa fa-eye"></i>
      </span>
      <span class="site-pv" title="总访问量">
        <span id="busuanzi_value_site_pv"></span>
      </span>
    </span>
</div>








      </div>
    </footer>
  </div>

  
  <script src="/lib/anime.min.js"></script>
  <script src="/lib/velocity/velocity.min.js"></script>
  <script src="/lib/velocity/velocity.ui.min.js"></script>

<script src="/js/utils.js"></script>

<script src="/js/motion.js"></script>


<script src="/js/schemes/muse.js"></script>


<script src="/js/next-boot.js"></script>




  




  
<script src="/js/local-search.js"></script>













  

  

  

</body>
</html>
